import request from '@/utils/request'

// 查询会话的聊天记录
export function getConversationMessages(query) {
  return request({
    url: `/api/conversation/${query.conversationId}/messages`,
    method: 'get',
    params: query
  })
}

// 删除聊天记录（逻辑删除）
export function deleteMessage(messageId) {
  return request({
    url: '/api/conversation/message/' + messageId,
    method: 'delete'
  })
}

// 恢复已删除的聊天记录
export function restoreMessage(messageId) {
  return request({
    url: `/api/conversation/message/${messageId}/restore`,
    method: 'put'
  })
} 